package com.threeox.commonlibrary.ui.view.impl;

import android.content.Context;

import com.threeox.commonlibrary.entity.engine.model.table.TableResultMessage;
import com.threeox.commonlibrary.ui.view.engineview.tablemodel.TableModelView;
import com.threeox.commonlibrary.ui.view.impl.base.CommonModelExtend;
import com.threeox.commonlibrary.ui.view.inter.engine.tablemodel.ITableModelExtend;

/**
 * 
 * @ClassName: AbstractTableModelExtend
 * 
 * @Description: TODO(抽象的表格模型扩展类)
 * 
 * @author 赵屈犇
 * 
 * @date 创建时间: 2017/8/10 14:23
 * 
 * @version 1.0
 * 
 */
public abstract class AbstractTableModelExtend<T> extends CommonModelExtend implements ITableModelExtend<T> {

    protected Context mContext;
    protected TableModelView mTableModelView;

    @Override
    public void init(Context context, TableModelView tableModelView) {
        this.mContext = context;
        this.mTableModelView = tableModelView;
        initBaseExtend(mTableModelView);
        initView();
        initData();
        setListener();
    }

    @Override
    public void OnTableRowClick(int position, T data) {

    }

    @Override
    public Boolean OnTableRowLongClick(int position, T data) {
        return null;
    }

    @Override
    public TableResultMessage onParseData(T datas) {
        return null;
    }

    @Override
    public boolean onBeforeParseData(TableResultMessage message) {
        return true;
    }

    @Override
    public void onAfterParseData(TableResultMessage datas) {

    }
}
